package com.hehe.Repository;

import com.hehe.POJO.Collect;
import jakarta.persistence.LockModeType;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Lock;

import java.util.List;
import java.util.Optional;


public interface CollectRepository extends JpaRepository<Collect, Long> {
    List<Collect> findByUsername(String username);


    Optional<Collect> findByUsernameAndPhotoId(String username, long photo_id);
}

